<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script src="https://cdn.staticfile.org/jquery/2.2.4/jquery.min.js"></script>
</head>
<style>
    * {
        margin: 0;
        padding: 0;

    }

    .box {
        height: 600px;
        width: 600px;
        position: relative;
        background: url('old.jpg');
        background-size: cover;
    }
    .new{
        background: url('new.jpg');
        width: 0;
        height: 600px;
        overflow: hidden;
        background-size: cover;
    }
    .box input[type=range] {
        bottom: 0;
        left: 0;
        position: absolute;
        width: 600px;
        opacity: 0.5;
        height: 30px;
    }
</style>

<body>
    <div class="box">
        <div class="new"></div>
        <input type="range" value="0">

    </div>

</body>
<script>
    $('.box input').mousemove(function(){
        $('.box .new').css('width',$(this).val()+'%');
    });
</script>
</html>